-
Notifications
You must be signed in to change notification settings - Fork 12.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added more scripts to tidy check #12243
Conversation
I think |
@@ -105,7 +115,9 @@ exports.runMode = function(string, modespec, callback) { | |||
if (string == "\n") | |||
accum.push("<br>"); | |||
else if (style) | |||
accum.push("<span class=\"cm-" + exports.htmlEscape(style) + "\">" + exports.htmlEscape(string) + "</span>"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can just break the line after +
, I think there's no need to split out onto different instructions.
Yes, let's whitelist codemirror-node.js and codemirror-rust.js, indicating that they are MIT licensed. It would probably be ok to put this license on them. |
I changed the push function and the licenses on the codemirror-* files, thanks for looking! |
@@ -422,7 +442,8 @@ CodeMirror.defineMode("rust", function() { | |||
type = lexical.type, closing = firstChar == type; | |||
if (type == "stat") return lexical.indented + indentUnit; | |||
if (lexical.align) return lexical.column + (closing ? 0 : 1); | |||
return lexical.indented + (closing ? 0 : (lexical.info == "match" ? altIndentUnit : indentUnit)); | |||
var text = (closing ? 0 : (lexical.info == "match" ? altIndentUnit : indentUnit)); | |||
return lexical.indented + text; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can also just break the line at the +
here.
Changed the line break there as well. |
Extends the license and formatting check to `*.js` files in `src/doc` and `*.sh`, `*.pl`, `*.c`, and `*.h` files in `src/etc`. As best as I could tell, these files should be covered under the Rust project license. cc @brson: Do any other scripts need a license? I'd like to double-check that this PR closes #4534.
I think it was just a fluke, but I rebased against master anyway. r? @alexcrichton |
Extends the license and formatting check to `*.js` files in `src/doc` and `*.sh`, `*.pl`, `*.c`, and `*.h` files in `src/etc`. As best as I could tell, these files should be covered under the Rust project license. cc @brson: Do any other scripts need a license? I'd like to double-check that this PR closes #4534.
FIX(12243): redundant_guards Fixed rust-lang#12243 changelog: Fix[`redundant_guards`] I have made a correction so that no warning does appear when y.is_empty() is used within a constant function as follows. ```rust pub const fn const_fn(x: &str) { match x { // Shouldn't lint. y if y.is_empty() => {}, _ => {}, } } ```
Extends the license and formatting check to
*.js
files insrc/doc
and*.sh
,*.pl
,*.c
, and*.h
files insrc/etc
. As best as I could tell, these files should be covered under the Rust project license.cc @brson: Do any other scripts need a license? I'd like to double-check that this PR closes #4534.